package com.yc.navy.dayfresh;

import org.mybatis.spring.annotation.MapperScan;
import org.springframework.boot.SpringApplication;
import org.springframework.boot.autoconfigure.SpringBootApplication;
import org.springframework.context.annotation.Bean;
import org.springframework.scheduling.annotation.EnableScheduling;
import org.springframework.transaction.annotation.EnableTransactionManagement;
import org.springframework.web.socket.server.standard.ServerEndpointExporter;

import javax.websocket.server.ServerEndpoint;

/**
 * Hello world!
 *
 */
@SpringBootApplication
@MapperScan("com.yc.navy.dayfresh.mapper")
// 开启事务管理
@EnableTransactionManagement
@EnableScheduling
public class FavApp
{
    public static void main( String[] args )
    {
        SpringApplication.run(FavApp.class, args);
    }

    @Bean
    public ServerEndpointExporter serverEndpointExporter(){
        return new ServerEndpointExporter();
    }
}
